package cn.edu.nyist.integration.mapper;

import cn.edu.nyist.integration.entity.ProductCredit;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface ProductCreditMapper {

    List<ProductCredit> selectByCategory(Integer categoryId);

    List<ProductCredit> selectAll(Integer categoryId);

    int deleteById(Long productId);

    int insertBySelect(ProductCredit productCredit);

    int updateScoreByName(@Param("score") Integer score, @Param("productName") String productName);

    List<String> selectProductNameByCategoryId(Integer categoryId);


    int selectScoreByName(String productName);
}
